package com.jdyinfo.ic.service;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.jdyinfo.ic.mysql.entity.UpTown;
import com.jdyinfo.ic.mysql.mapper.UpTownMapper;

@Service("upTownService")
public class UpTownService {
	@Autowired
	UpTownMapper upTownMapper;
	
	public List<UpTown> findUpTown(int tenantId) {
		return upTownMapper.findUpTownByTenantId(tenantId);
	}
	
	public int createUpTown(UpTown upTown) {
		return upTownMapper.insertOne(upTown);
	}
	
	public int updateUpTown(UpTown upTown) {
		return upTownMapper.updateOne(upTown);
	}
	
}
